//
// Created by root on 19-7-29.
//
#pragma once
#ifndef SYSTEMDEBUGGER_DEX_UTILS_H
#define SYSTEMDEBUGGER_DEX_UTILS_H

#include <jni.h>
#include <string>

void patch_class_loader(JNIEnv *env, jobject target, jobject dex_class_loader);
jobject get_sys_classloader(JNIEnv *env);
jobject new_dex_class_loader(JNIEnv *env,const char* dex_path, const char* opt_path,const char* lib_path);
jobject get_loaded_dex(const char* dex_path);
jclass load_by_specific_classloader(JNIEnv *env,jobject class_loader,const char* class_name_wp);
jobject get_app_classloader(JNIEnv *env);
std::string get_package_name(JNIEnv *env,jobject context);
jobject get_app_context(JNIEnv *env);
jstring get_dir(JNIEnv *env,const char* name);
#endif //SYSTEMDEBUGGER_DEX_UTILS_H
